package com.binance.notification.data.mapper;

import com.binance.master.annotations.DefaultDB;
import com.binance.notification.data.models.MessageType;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author lufei
 * @date 2018/11/2
 */
@DefaultDB
public interface MessageTypeMapper {

    Long checkUnique(@Param("name") String name);

    Integer save(MessageType messageType);

    Integer update(MessageType messageType);

    Integer delete(@Param("id") Long id);

    MessageType getById(@Param("id") Long id);

    List<MessageType> select(@Param("mt") MessageType messageType, @Param("position") Integer position, @Param("rows") Integer rows);

    Long selectCount(@Param("mt") MessageType messageType);

}
